#include "Precompiled.hpp"

template <class TemplatedClass>
Handle<TemplatedClass>::Handle()
{}

template <class TemplatedClass>
Handle<TemplatedClass>::Handle(FactoryInterface* myFactory_, unsigned int index_, unsigned int ID_) : TypelessHandle(myFactory_, index_, ID_)
{}

template <class TemplatedClass>
Handle<TemplatedClass>::Handle(const TypelessHandle& rhs) : TypelessHandle(rhs)
{
}

template <class TemplatedClass>
Handle<TemplatedClass>::~Handle()
{}

template <class TemplatedClass>
Handle<TemplatedClass>::operator TypelessHandle ()
{
  return TypelessHandle;
}

template <class TemplatedClass>
TemplatedClass* Handle<TemplatedClass>::GetTypedData()
{
  return reinterpret_cast<TemplatedClass*>(GetData());
}

template <class TemplatedClass>
const TemplatedClass* Handle<TemplatedClass>::GetTypedData() const
{
  return reinterpret_cast<const TemplatedClass*>(GetData());
}

template <class TemplatedClass>
TemplatedClass* Handle<TemplatedClass>::operator -> ()
{
  return GetTypedData();
}

template <class TemplatedClass>
const TemplatedClass* Handle<TemplatedClass>::operator -> () const
{
  return GetTypedData();
}

template <class TemplatedClass>
TemplatedClass& Handle<TemplatedClass>::operator * ()
{
  return *GetTypedData();
}

template <class TemplatedClass>
const TemplatedClass& Handle<TemplatedClass>::operator * () const
{
  return *GetTypedData();
}